package com.chen.dao.role;

import java.util.List;

import org.apache.ibatis.annotations.Mapper;

import com.chen.pojo.Role;
@Mapper
public interface RoleDao {
	/**
	 * ��ѯ���н�ɫ��Ϣ
	 * @return
	 * @throws Exception
	 */
	public List<Role> getRoleList()throws Exception;
	/**
	 * ����һ����ɫ��Ϣ
	 * @param role
	 * @return
	 * @throws Exception
	 */
	public int addRole(Role role) throws Exception;
	/**
	 * �޸�һ����ɫ��Ϣ
	 * @param role
	 * @return
	 * @throws Exception
	 */
	public int updateRole(Role role) throws Exception;
	/**
	 * ɾ��һ����ɫ��Ϣ
	 * @param delId
	 * @return
	 * @throws Exception
	 */
	public int deleteRole(String delId) throws Exception;
	/**
	 * ���ݽ�ɫ�����ѯ��ɫ�Ƿ����
	 * @param roleCode
	 * @return
	 * @throws Exception
	 */
	public Role getRole(String roleCode) throws Exception;
	
	/**
	 * ���ݽ�ɫid��ѯ��ɫ�Ƿ����
	 * @param id
	 * @return
	 * @throws Exception
	 */
	public Role getRoleById(String id) throws Exception;

}
